<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>  
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">  
<html>  
  <head>  
    <title>角色列表</title> 
    <%@ include file="../admin/head.jsp"%> 
	<script type="text/javascript" src="../resource/js/role/list.js?v=8"></script>
  </head>  
    
  <body>  
  	
  	<table id="dg" class="easyui-datagrid"
            data-options="rownumbers:true,singleSelect:false,pagination:true,pageSize:20,fitColumns:true,fit:true"
            toolbar="#toolbar">
       <thead>
           <tr>
           		<th data-options="field:'id',checkbox:true"></th>
           		<th data-options="field:'roleName',width:80,align:'center'">角色名称</th>
           		<th data-options="field:'createDate',width:80,align:'center'">创建时间</th>
           		<th data-options="field:'roleRemark',width:80,align:'center'">备注</th>
           </tr>
       </thead>
    </table>
    <div id="toolbar" style="text-align:left;">
   		 <a href="#" id="toAdd" class="easyui-linkbutton" iconCls="icon-add" plain="true" onclick="toAdd()">新增</a>
   		 <a href="#" id="toEdit" class="easyui-linkbutton" iconCls="icon-edit" plain="true" onclick="toEdit()">修改</a>
   		 <a href="#" id="del" class="easyui-linkbutton" iconCls="icon-cut" plain="true" onclick="del()">删除</a>
   		 <a href="#" id="ext" class="easyui-linkbutton" iconCls="icon-redo" plain="true" onclick="ext()">导出</a>
   		 <a href="#" id="toPrivilege" class="easyui-linkbutton" iconCls="icon-add" plain="true" onclick="toPrivilege()">分配权限</a>
	 	 <input type="text" name="keyWord" id="keyWord" placeholder="输入搜索内容" style="margin-left: 10"/>
  		 <a href="#" class="easyui-linkbutton" iconCls="icon-search" plain="true" onClick="_search()">搜索</a>
  		 <a href="#" class="easyui-linkbutton" iconCls="icon-reload" plain="true" onClick="reset()">重置</a>
    </div>
  	
  	
  	<!-- 表单窗口 -->
  	<div id="win" class="easyui-window" style="width:300px;height:180px"
    	data-options="modal:true,closed:true,collapsible:false,minimizable:false,maximizable:false">
    	<form id="fm">
    		<input type="hidden" name="id" id="id"/>
    		<table style="margin:15 auto;" cellspacing="5">
    		 	<tr>
    				<td>角色名称：</td>
    				<td><input type="text" id="roleName" name="roleName" class="easyui-validatebox tb" data-options="required:true,validType:'length[1,20]'"/></td>
    			</tr>
    		 	<tr>
    				<td>信息备注：</td>
    				<td><input type="text" id="roleRemark" name="roleRemark" /></td>
    			</tr>
    		</table>
    		<div style="text-align:center;">
		        <a href="javascript:void(0)" class="easyui-linkbutton c6" iconCls="icon-ok" onclick="save()" style="width:90px">保存</a>
		        <a href="javascript:void(0)" class="easyui-linkbutton" iconCls="icon-cancel" onclick="javascript:$('#win').window('close')" style="width:90px">取消</a>
		    </div>	
    	</form>
	</div>
	
	<!-- 分配权限窗口 -->
  	<div id="privilegeWin" class="easyui-window" style="width:300px;height:400px"
    	data-options="modal:true,closed:true,collapsible:false,minimizable:false,maximizable:false">
    	<ul id="privilegeTree"></ul>
    	<div style="text-align:center;">
	        <a href="javascript:void(0)" class="easyui-linkbutton c6" iconCls="icon-ok" onclick="savePrivilege()" style="width:90px">保存</a>
	        <a href="javascript:void(0)" class="easyui-linkbutton" iconCls="icon-cancel" onclick="javascript:$('#privilegeWin').window('close')" style="width:90px">取消</a>
	    </div>	
	</div>
  </body>  
</html>  